<?php
/**
 * Created by PhpStorm.
 * User: Admin
 * Date: 2019/11/14
 * Time: 11:39
 */

require_once  "./../vendor/autoload.php";

$checkers = [
    new \DuRequest\Checker\lib\MustChecker("a","a必须存在"),

];
$rule = new \DuRequest\Checker\lib\Rule($checkers , new \Request\Checker\lib\RequestData($_POST));
if(!$rule->validate()){
    var_dump($rule->getErrors());
}